package Others.DesignPattern.ProxyPattern.Pattern.Object;

import lombok.Data;

@Data
public class Broker implements give {

    private Pursuit pursuit;

    public Broker(BePursued bePursued){
        this.pursuit = new Pursuit(bePursued);
    }

    public void giveDolls() {
        pursuit.giveDolls();
    }

    public void giveFlowers() {
       pursuit.giveFlowers();
    }

    public void giveChocolates() {
        pursuit.giveChocolates();
    }

    //这个broker相当于是第三方代理类--它里面的内容不是自己的，全部都是他人的，只是在他这里做了一个中转

}
